import { ref } from 'vue';
import pageContent from '@/components/pageContent';

export const hi = function () {
  console.log(233);
};

export const usePageSearch = function () {
  const pageContentRef = ref<InstanceType<typeof pageContent>>();

  const search = function (value: any) {
    pageContentRef.value?.getPageData(value);
  };

  const reset = function () {
    pageContentRef.value?.getPageData();
  };

  return {
    search,
    reset,
    pageContentRef,
  };
};
